CC=gcc
FLAGS=-g -fPIC -O2 -I../../ `sdl-config --cflags`
LDFLAGS=`sdl-config --cflags --libs` -lSDL_mixer


all:
	$(CC) $(FLAGS) -c -o redaudio.o redaudio.cpp
	$(CC) -shared -o redaudio.so redaudio.o $(LDFLAGS)
	chmod a-x redaudio.so
	rm *.o

install:
	mv *.so ../../../modules/

clean:
	rm *~ *.o ../../../modules/redaudio.so
